package program;

import java.util.*;

public class TrackManager {

	private ArrayList<Track> listOfTracks = new ArrayList<Track>();
	
	public TrackManager() {
	}
	
	//add new track to list of tracks
	public void addTrack(Station a, Station b, float len, int aveTime, boolean use){
		if(a==null || b==null || len==Float.NaN){
			throw new IllegalArgumentException("Arguments cannot be null");
		}
		
		Track t = new Track(a,b,len,aveTime,use);
		listOfTracks.add(t);
	}
	
	//return list of tracks
	public ArrayList<Track> getTracks(){
		return listOfTracks;		
	}
	
	
}
